<!DOCTYPE html>
<html>

<head>
    <title></title>
    <link rel='stylesheet' href='/stylesheets/common.css' />
    <link rel='stylesheet' href='/stylesheets/style.css' />
</head>

<body>
    <ul>
        <%for(var i=0; i<userList.length; i++){%>
        <li>
            <%= userList[i].username %>
        </li>
        <%}%>
    </ul>
    <img src='/images/psc2(2).png'/>
</body>
<script>
    fetch("http://localhost:3000/test?userid=10&age=20")
    .then(res=>res.json())
    .then(res=>{
        console.log(res);
    })
    fetch("http://localhost:3000/show/1")
    .then(res=>res.text())
    .then(res=>{
        console.log(res);
    })

    var obj={username:"zhangsan",pwd:'12345'}
    fetch("http://localhost:3000/login",{
        method:'POST',
        body:JSON.stringify(obj)
    }).then(res=>res.json())
    .then(res=>{
        console.log(res);
    })
</script>

</html>